package xyz.hubery.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import org.springframework.stereotype.Service;
import org.springframework.beans.factory.annotation.Autowired;

import java.util.Collections;
import java.util.List;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import xyz.hubery.domain.WebConfig;
import xyz.hubery.mapper.WebConfigMapper;
import xyz.hubery.service.WebConfigService;
@Service
public class WebConfigServiceImpl extends ServiceImpl<WebConfigMapper, WebConfig> implements WebConfigService{

    @Override
    public List<WebConfig> listBanners() {
        return list(new LambdaQueryWrapper<WebConfig>().eq(WebConfig::getType, "WEB_BANNER").orderByAsc(WebConfig::getSort).eq(WebConfig::getStatus,1));
    }
}
